package o;

import com.google.android.exoplayer2.ParserException;
import java.io.IOException;

public class alm implements alu {
    private final int ˊ;

    public alm() {
        this(-1);
    }

    public alm(int i) {
        this.ˊ = i;
    }

    public long ˋ(int i, long j, IOException iOException, int i2) {
        if (iOException instanceof ParserException) {
            return -9223372036854775807L;
        }
        return (long) Math.min((i2 - 1) * 1000, 5000);
    }

    public int ˎ(int i) {
        if (this.ˊ == -1) {
            return i == 7 ? 6 : 3;
        } else {
            return this.ˊ;
        }
    }
}
